xen/arm: arm64: Add Cortex-A57 erratum 834220 workaround
authorJulien Grall <julien.grall@arm.com>
Thu, 4 Aug 2016 17:50:07 +0000 (18:50 +0100)
committerStefano Stabellini <sstabellini@kernel.org>
Thu, 4 Aug 2016 17:56:44 +0000 (10:56 -0700)
commit0a7ba29364576deb4c13b3bb4cf7d03136bead98
treef19b4bee7d7b6136a3c8b394eef2ca7d2553f0c9
parent4b3b430fcb09823177fc44e96901458ac5a399de
xen/arm: arm64: Add Cortex-A57 erratum 834220 workaround

The ARM erratum applies to certain revisions of Cortex-A57. The
processor may report a Stage 2 translation fault as the result of
Stage 1 fault for load crossing a page boundary when there is a
permission fault or device memory fault at stage 1 and a translation
fault at Stage 2.

So Xen needs to check that Stage 1 translation does not generate a fault
before handling the Stage 2 fault. If it is a Stage 1 translation fault,
return to the guest to let the processor injecting the correct fault.

Signed-off-by: Julien Grall <julien.grall@arm.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
docs/misc/arm/silicon-errata.txt
xen/arch/arm/Kconfig
xen/arch/arm/cpuerrata.c
xen/arch/arm/traps.c
xen/include/asm-arm/cpuerrata.h
xen/include/asm-arm/cpufeature.h